﻿using Android.App;
using Android.Content;
using Android.OS;
using Android.Runtime;
using Android.Views;
using Android.Widget;
using nhCore.Modbus;
using nhCore.Modbus.Frame;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace nhCore
{
    /// <summary>
    /// 蓝牙温湿压测量仪，增加字符串帧
    /// </summary>
    internal class CjkjDevice : SensorDevice
    {
        public CjkjDevice()
        {
            Name = "蓝牙设备";
        }

        public override List<CmdFrame> GetSentCmds(byte code = 0x04, int workDelayTime = 1000, int sleepDelayTime = 1000)
        {
            List<CmdFrame> ls = base.GetSentCmds(code, workDelayTime, sleepDelayTime);

            //读出序列号
            ReadSnCmd rtc = new ReadSnCmd(0, 0)//0延时立即发送
            {
                Automatic = false,//仅一次
            };
            ls.Add(rtc);

            return ls;
        }
    }
}